﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeBehind="Addmaterial.aspx.cs" Inherits="lcs.Web.project.Addmaterial" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
<script src="../Scripts/JsTools.js"></script>
     <script src="../Scripts/mybase.js"></script>
    <script src="../js/CheckBox.js"></script>
    <link href="../jquery-ui.min.css" rel="stylesheet" />    
    <script src="../js/jquery-ui.min.js"></script>
    <style type="text/css">
        td { font-size: 9pt}
        a { color:Blue; text-decoration: none}
        body{ font-size:9pt;}
     </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
     <table style="width: 100%;" cellpadding="2" cellspacing="1" class="border">
                <tr>
                    <td style="width: 80px" align="right" class="tdbg">
                         <b>物料名：</b>
                    </td>
                    <td class="tdbg">
                        <asp:TextBox ID="txtKeyword" runat="server" width="200px"></asp:TextBox> 
                    <asp:Button ID="btnSearch" runat="server" Text="查询"  OnClick="btnSearch_Click" >
                    </asp:Button>                    
                        目的项目：<asp:Label ID="lbl_projectname" 
              runat="server"></asp:Label>
                    </td>
                    <td class="tdbg">
                    </td>
                </tr>
            </table>
            <!--Search end-->
            <br />
            <asp:GridView ID="gridView" runat="server" AllowPaging="True" Width="100%" BorderWidth="0px" CellPadding="0" CellSpacing="1" CssClass="gv" GridLines="None"  OnPageIndexChanging ="gridView_PageIndexChanging"
                     DataKeyNames="material_id,out_storageList_id" OnRowDataBound="gridView_RowDataBound" 
                    AutoGenerateColumns="false" PageSize="15"  RowStyle-HorizontalAlign="Center" OnRowCreated="gridView_OnRowCreated">
                    <Columns>
                         <asp:TemplateField ControlStyle-Width="30" HeaderText="选择"    >
                               <%--<HeaderTemplate>
                                    <input id="Checkbox1" type="checkbox" onclick="chall(this)" />
                                </HeaderTemplate>--%>
                                <ItemTemplate>
                                    <asp:CheckBox ID="DeleteThis" runat="server" />
                                </ItemTemplate>
                            </asp:TemplateField>  
                       <%-- <asp:TemplateField HeaderText="数量">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("out_storage_count") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="lbl_venNums" runat="server" Text='<%# Bind("out_storage_count") %>'></asp:Label>
                        
                    </ItemTemplate>
                </asp:TemplateField>--%>
                       <asp:BoundField DataField="out_storage_count" HeaderText="出库量" />
                         <asp:BoundField DataField="snums" HeaderText="分码量" />
                         <asp:BoundField DataField="synums" HeaderText="剩余量" />
                <asp:BoundField DataField="material" HeaderText="物料描述" />                
                <asp:BoundField DataField="mbm" HeaderText="物料编码" />
                    </Columns>
                </asp:GridView>
    <table border="0" cellpadding="0" cellspacing="1" style="width: 100%;">
                <tr>
                    <td style="width: 1px;">                        
                    </td>
                    <td align="left">
                       数量：<asp:TextBox ID="txtnums" runat="server" width="200px"></asp:TextBox> <asp:Button ID="btnadd" runat="server" Text="添加" OnClick="btnadd_Click"/>                       
                    </td>
                </tr>
            </table>
    <div style=" margin-top:10px; text-align :center;">        
        <asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" DataKeyNames="fmmid"
            Width="100%" BorderWidth="0px" CellPadding="0" CellSpacing="1" CssClass="gv" GridLines="None"
             onRowDeleting="gridView_RowDeleting">
            <Columns> 
                <asp:BoundField DataField="material" HeaderText="物料描述" />
                <asp:BoundField DataField="nums" HeaderText="数量"  DataFormatString="{0:0.00}"/>
                <%--<asp:HyperLinkField HeaderText="编辑" ControlStyle-Width="50" DataNavigateUrlFields="mid" DataNavigateUrlFormatString="Modify.aspx?id={0}"
                                Text="编辑"  />--%>
                            <asp:TemplateField ControlStyle-Width="50" HeaderText="删除"   Visible="true"  >
                                <ItemTemplate>
                                    <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Delete"
                                         Text="删除"></asp:LinkButton>
                                </ItemTemplate>
                            </asp:TemplateField>
            </Columns>
            <PagerStyle CssClass="mypager" />
        </asp:GridView>
    </div>
</asp:Content>
